Class TXLSReadWriteII5

DescriptionHierarchyFieldsMethodsProperties

Unit

Declaration

type TXLSReadWriteII5 = class(TXLSWorkbook)

Description

no description available, TXLSWorkbook description follows

Hierarchy

Overview

Methods

Public constructor Create(AOwner: TComponent); override;
Public destructor Destroy; override;
Public procedure Clear(ADefaulSheetsCount: integer = 1);
Public procedure Read;
Public procedure LoadFromFile(AFilename: AxUCString);
Public procedure LoadFromStream(AStream: TStream; const AAutoDetect: boolean = True);
Public procedure LoadFromStream97(AStream: TStream);
Public procedure Write;
Public procedure SaveToFile(AFilename: AxUCString);
Public procedure SaveToStream(AStream: TStream);
Public procedure SetDirectWriteArea(const ASheetIndex,ACol1,ARow1,ACol2,ARow2: integer);

Properties

Public property BIFF: TBIFF5 read FBIFF;
Public property ReadVBA: boolean read FReadVBA write FReadVBA;
Public property StrTRUE: AxUCString read GetStrTRUE write SetStrTRUE;
Public property StrFALSE: AxUCString read GetStrFALSE write SetStrFALSE;
Public property Password: AxUCString read GetPassword write SetPassword;
Public property Manager: TXc12Manager read FManager;
Published property ComponentVersion: AxUCString read GetVersionNumber write SetVerionNumber;
Published property Version: TExcelVersion read GetVersion write SetVersion;
Published property Filename: AxUCString read GetFilename write SetFilename;
Published property DirectRead: boolean read GetDirectRead write SetDirectRead;
Published property DirectWrite: boolean read GetDirectWrite write SetDirectWrite;
Published property Errors: TXLSErrorManager read FErrors;
Published property OnReadCell : TCellReadWriteEvent read GetCellReadEvent write SetCellReadEvent;
Published property OnWriteCell: TCellReadWriteEvent read GetCellWriteEvent write SetCellWriteEvent;
Published property OnPassword : TPasswordEvent read FPasswordEvent write FPasswordEvent;
Published property OnFunction : TFunctionEvent read FFunctionEvent write FFunctionEvent;
Published property OnProgress : TXLSProgressEvent read GetProgressEvent write SetProgressEvent;

Description

Methods

Public constructor Create(AOwner: TComponent); override;
 
Public destructor Destroy; override;
 
Public procedure Clear(ADefaulSheetsCount: integer = 1);

Deletes all data from the workbook and adds ADefaulSheetsCount worksheets.

Public procedure Read;

Reads the Excel file give by Filename.

Public procedure LoadFromFile(AFilename: AxUCString);

Does the same thing as Filename and Read but in one call. The Filename property is set to AFilname.

Public procedure LoadFromStream(AStream: TStream; const AAutoDetect: boolean = True);

Reads an Excel file from a stream. If AAutoDetect is True the method will try to detect if the stream is an Excel 2007 or an Excel 97 stream. If you explicite want to read an Excel 97 file, use LoadFromStream97.

Public procedure LoadFromStream97(AStream: TStream);

Reads an Excel 97 file from a stream. If you want to read an Excel 2007+ file, use LoadFromStream.

Public procedure Write;

Writes the data the file give by Filename.

Public procedure SaveToFile(AFilename: AxUCString);

Does the same thing as Filename and Write but in one call. The Filename property is set to AFilname.

Public procedure SaveToStream(AStream: TStream);

Saves the data to a stream.

Public procedure SetDirectWriteArea(const ASheetIndex,ACol1,ARow1,ACol2,ARow2: integer);

Sets the are you want to fill with cell values when using DirectWrite.

Properties

Public property BIFF: TBIFF5 read FBIFF;
 
Public property ReadVBA: boolean read FReadVBA write FReadVBA;
 
Public property StrTRUE: AxUCString read GetStrTRUE write SetStrTRUE;

Change StrTRUE property to change the string representation of the boolean value True. The default is 'TRUE'. See also StrFALSE

Public property StrFALSE: AxUCString read GetStrFALSE write SetStrFALSE;

Change StrFALSE property to change the string representation of the boolean value False. The default is 'FALSE'. See also StrTRUE

Public property Password: AxUCString read GetPassword write SetPassword;

The password for encrypted files.

Public property Manager: TXc12Manager read FManager;
 
Published property ComponentVersion: AxUCString read GetVersionNumber write SetVerionNumber;

The version of the TXLSReadWriteII5 component.

Published property Version: TExcelVersion read GetVersion write SetVersion;

The Excel file version for the workbook. When reading files, Version is set according to the file extension.
xls and xlm = xvExcel97 xlsx and xlsm = xvExcel2007 See also Xc12Utils5.TExcelVersion, a_ExcelFiles

Published property Filename: AxUCString read GetFilename write SetFilename;

The name of the Excel file.

Published property DirectRead: boolean read GetDirectRead write SetDirectRead;

When DirectRead mode is active, the cell values are not stored in memory. Instead is the OnReadCell event fired when a cell is read. You can then access the cell value in the Xc12Manager5.TXLSEventCell object, ACell parameter, in the event.
The advantage with the DirectRead mode is that no memory is used for storing cell values. As Excel 2007+ files can have 100 of millions of cells this can be a greate memory save. If you know that you just want a few cells, or going to store them elsewhere, this is a good choice. See also DirectWrite.

Published property DirectWrite: boolean read GetDirectWrite write SetDirectWrite;

DirectWrite mode writes cell values directly to the disk file instead of first storing them in memory. This can save hughe ammount of memory if you are writing large files. See also DirectRead.

Published property Errors: TXLSErrorManager read FErrors;

Error manager. See XLSUtils5.TXLSErrorManager.

Published property OnReadCell : TCellReadWriteEvent read GetCellReadEvent write SetCellReadEvent;
 
Published property OnWriteCell: TCellReadWriteEvent read GetCellWriteEvent write SetCellWriteEvent;
 
Published property OnPassword : TPasswordEvent read FPasswordEvent write FPasswordEvent;
 
Published property OnFunction : TFunctionEvent read FFunctionEvent write FFunctionEvent;
 
Published property OnProgress : TXLSProgressEvent read GetProgressEvent write SetProgressEvent;
 

Generated by PasDoc 0.12.1 on 2013-03-18 12:36:48